all : bin/mp2gzip
obj/vd_unsignedint.o : src/vd_unsignedint.cpp include/vd_unsignedint.h
	g++ -c -Wall -Iinclude src/vd_unsignedint.cpp -o obj/vd_unsignedint.o
obj/vd_unsignedchar.o : src/vd_unsignedchar.cpp include/vd_unsignedchar.h
	g++ -c -Wall -Iinclude src/vd_unsignedchar.cpp -o obj/vd_unsignedchar.o
obj/tabla.o : src/tabla.cpp include/tabla.h include/vbits.h
	g++ -c -Wall -Iinclude src/tabla.cpp -o obj/tabla.o
obj/vbits.o : src/vbits.cpp include/vbits.h include/vd_unsignedchar.h
	g++ -c -Wall -Iinclude src/vbits.cpp -o obj/vbits.o
obj/lz77.o : src/lz77.cpp include/lz77.h include/vd_unsignedchar.h include/vd_unsignedint.h include/vbits.h include/tabla.h
	g++ -c -Wall -Iinclude src/lz77.cpp -o obj/lz77.o
clean:
	\rm -rf obj/*.o src/*~ include/*~ lib/libvd.a
mrproper: clean
	\rm -rf bin/*
lib/libvd.a : obj/vd_unsignedint.o obj/vd_unsignedchar.o
	ar rsv lib/libvd.a obj/vd_unsignedchar.o obj/vd_unsignedint.o
obj/deflate.o : src/deflate.cpp include/deflate.h include/lz77.h include/tabla.h lib/libvd.a
	g++ -c -Wall -Iinclude src/deflate.cpp -o obj/deflate.o -Llib -lvd
obj/mp2gzip.o : src/mp2gzip.cpp include/vbits.h include/tabla.h lib/libvd.a
	g++ -c -Wall -Iinclude src/mp2gzip.cpp -o obj/mp2gzip.o -Llib -lvd
bin/mp2gzip : obj/mp2gzip.o obj/vbits.o obj/tabla.o obj/lz77.o obj/deflate.o lib/libvd.a
	g++ obj/mp2gzip.o obj/lz77.o obj/vbits.o obj/tabla.o obj/deflate.o -o bin/mp2gzip -Llib -lvd

